/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package models;

import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;

/**
 *
 * @author Misja
 */
public class Twitterer implements Serializable{

    private int id;
    private String userName;
    private String password;
    private boolean canPlace;
    private boolean platinumTwitterer;
    private Set<Twitterer> favorites;

    public Twitterer() {
        this.canPlace = true;
        this.platinumTwitterer = false;
        this.favorites = new HashSet<Twitterer>();
    }

    public Twitterer(String userName, String password) {
        this.userName = userName;
        this.password = password;
        this.canPlace = true;
        this.platinumTwitterer = false;
        this.favorites = new HashSet<Twitterer>();
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public boolean isCanPlace() {
        return canPlace;
    }

    public void setCanPlace(boolean canPlace) {
        this.canPlace = canPlace;
    }

    public boolean isPlatinumTwitterer() {
        return platinumTwitterer;
    }

    public void setPlatinumTwitterer(boolean platinumTwitterer) {
        this.platinumTwitterer = platinumTwitterer;
    }

    public Set<Twitterer> getFavorites() {
        return favorites;
    }

    public void setFavorites(Set<Twitterer> favorites) {
        this.favorites = favorites;
    }

    public void setFavorite(Twitterer twitterer) {
        this.favorites.add(twitterer);
    }
}
